{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Chris Holden (ceholden@gmail.com) - https://github.com/ceholden\n",
    "\n",
    "Introduction\n",
    "============\n",
    "\n",
    "Tutorial of basic remote sensing and GIS methodologies using open source software (GDAL in Python)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Why Python?\n",
    "- Easy to learn\n",
    "    - Python is an interpreted, dynamically typed language with little boilerplate code required to begin doing useful things\n",
    "    - Test out your code in Python's interpreter (read-evaluate-print loop) before you put your code into a script\n",
    "    - Very readible and closer to human thoughts than C/Java/R/MATLAB\n",
    "    \n",
    "- Python is an actual programming language with a large standard library\n",
    "    - tools for file manipulation, command line argument parsing, and web access and parsing already exist and are robust\n",
    "    - Python already widely used in other scientific communities and outside of science for web servers, desktop applications, and server management\n",
    "    \n",
    "- Scientific Python provides very well documented and easy to use interfaces to pre-existing numeric methods\n",
    "    - Linear alebgra, classification routines, regression methods, and more have been published for decades as Fortran or C codes\n",
    "    - Libraries such as SciPy, NumPy, and SciKits wrap and extend these pre-existing codes in an easy to use package\n",
    "    - Python provides numerous tools to introspect objects and Python code conventions make access of documentation easy (e.g., type `?np.random.randint` to access the documentation string (docstring) of NumPy random number generator\n",
    "    \n",
    "- Large community with innumerable examples on blogs, StackOverflow, Github, etc.\n",
    "\n",
    "- Develop Python plugins for QGIS\n",
    "\n",
    "- Script analyses in QGIS or ArcMap\n",
    "\n",
    "- Many GDAL tools written in Python\n",
    "    - useful for example code and a strong recommendation\n",
    "\n",
    "- Free"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Chapters\n",
    "1. [Exploring the GDALDataset class](chapter_1_GDALDataset.ipynb)\n",
    "2. [Your first remote sensing vegetation index](chapter_2_indices.ipynb)\n",
    "3. [Plotting and visualizing your data with `matplotlib`](chapter_3_visualization.ipynb)\n",
    "4. [Importing and using vector data -- the OGR library](chapter_4_vector.ipynb)\n",
    "5. [Classification of land cover](chapter_5_classification.ipynb)\n",
    "6. [The spatial dimension - filters and segmentation](chapter_6_spatial.ipynb)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Other resources\n",
    "There are many resources for doing remote sensing and GIS with Python on the web, but here are some of the better ones:\n",
    "- [Chris Garrard's course material from Utah State University](http://www.gis.usu.edu/~chrisg/python/2009/)\n",
    "- [Python GDAL/OGR cookbook](http://pcjericks.github.io/py-gdalogr-cookbook/)\n",
    "- [GDAL API tutorial](http://www.gdal.org/gdal_tutorial.html)\n",
    "- [Python API for GDAL](http://gdal.org/python/)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### Note on Python 2 vs Python 3\n",
    "\n",
    "This tutorial will try to target either Python 2.7 or Python 3.4 and 3.5. To ensure you're using a compatible version of Python, you can run the following:\n",
    "\n",
    "    python --version\n",
    "    \n",
    "at the command line.\n",
    "\n",
    "Python 3 has many great new features (more informative stack traces, better unicode handling, `asyncio`, matrix algebra notation using `@`, and more) and is the future of the language. Unfortunately, some scientific packages (QGIS, for example) have not yet completed the transition away from Python 2. Unless you have good reason to use Python 2 (like if you're writing a QGIS plugin in Python), the general concensus is to recommend using Python 3."
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.4.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}
